package com.wanmait.demo.controller.manageController;

import com.wanmait.demo.pojo.Role;
import com.wanmait.demo.service.RoleService;
import com.wanmait.demo.util.Layui;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;
import org.springframework.web.servlet.ModelAndView;

import javax.annotation.Resource;
import java.util.List;

@Controller
public class RoleManageController {
    @Resource
    private RoleService roleService;


    @RequestMapping("roleManage")
    @ResponseBody
    public Layui<Role> roleManage()
    {

        Layui<Role> roleLayui=roleService.findRole();

        return roleLayui;
    }
    @RequestMapping("getRole")
    public String adminManage()
    {
        return "/manage/roleManage";
    }
}
